package top.zhangjianyong.tools.constant;

public enum MaiRuiApiPath {

    JJ_ALL(MaiRuiConfig.URL + "/jj/all"),
    JJ_JJGK(MaiRuiConfig.URL + "/jj/jjgk"),
    JJ_ZCPZ(MaiRuiConfig.URL + "/jj/zcpz"),
    JJ_GPCC(MaiRuiConfig.URL + "/jj/gpcc"),//持仓
    JJ_ETF(MaiRuiConfig.URL + "/jj/etf"),
    JJ_ETF_HQ(MaiRuiConfig.URL + "/jj/etfhq"),
    JJ_ZXKX(MaiRuiConfig.URL + "/jj/zxkx"),
    JJ_LSKX(MaiRuiConfig.URL + "/jj/lskx"),
    JJ_LSJZ(MaiRuiConfig.URL + "/jj/lsjz"),
    HSRL_SSJY(MaiRuiConfig.URL + "/hsrl/ssjy"),
    HSCP_CWZB(MaiRuiConfig.URL + "/hscp/cwzb"),
    HSCP_JDLR(MaiRuiConfig.URL + "/hscp/jdlr/"),
    HF_REAL_TIME(MaiRuiConfig.URL + "/hf/real/time"),
    ;


    private final String url;

    MaiRuiApiPath(String url) {
        this.url = url;
    }

    public String getUrl(String licence) {
        return this.url + "/" + licence;
    }

    public String getUrl(String code, String licence) {
        return this.url + "/" + code + "/" + licence;
    }

    public String getUrl(String code, MaiRuiLevel level, String licence) {
        return this.url + "/" + code + "/" + level.value + "/" + licence;
    }
}
